package pers.litao.bit.order.controller;

import org.aspectj.weaver.ast.Var;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import pers.litao.bit.commons.utils.R;
import pers.litao.bit.commons.utils.SysUtil;
import pers.litao.bit.order.service.RetailWeekService;

import javax.servlet.http.HttpServletRequest;

/**
 * @author 李涛
 * @date 2020-12-21 14:15
 */
@RestController
@RequestMapping("/order/retailweek")
public class RetailWeekController {
    @Autowired
    private RetailWeekService retailWeekService;

    /**
     * 零售商周统计
     *
     * @param request
     * @return
     */
    @RequestMapping("/week")
    public R getWeek(HttpServletRequest request){
        return retailWeekService.getWeek(SysUtil.getLoginUserInfo(request));
    }
}
